package org.summerframework.core.annotation;

import org.springframework.core.annotation.AliasFor;

import java.lang.annotation.*;

/**
 * 类似RequestParam, 只不过作用于复杂对象中
 *
 * @author 石超
 * @version v1.0.0
 */
@Target({ElementType.FIELD, ElementType.TYPE})
@Retention(RetentionPolicy.RUNTIME)
@Documented
public @interface ParamName {
    @AliasFor("name")
    String value() default "";

    /**
     * @return 对应的request中的paramName, 默认为field本身
     */
    @AliasFor("value")
    String name() default "";
}
